﻿Public Class DealsRSSFeed
    Inherits System.Web.UI.Page

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

    End Sub

    Protected Function FormatForXML(ByVal input As Object) As String
        Dim data As String = input.ToString()
        ' cast the input to a string
        ' replace those characters disallowed in XML documents
        data = data.Replace("&", "&amp;")
        data = data.Replace("""", "&quot;")
        data = data.Replace("'", "&apos;")
        data = data.Replace("<", "&lt;")
        data = data.Replace(">", "&gt;")

        Return data
    End Function
End Class